#include <stdio.h>

int main(int argc, char const *argv[])
{
    int num = 0;
    printf("请输入一个int数据:");
    scanf("%d", &num);

    if (num >= 100) {
        printf("error \n");
    }

    if(num >= 90) {
        printf("A \n");
    } else if(num >= 80) {
        printf("B \n");
    } else if(num >= 70) {
        printf("C \n");
    } else {
        printf("D \n");
    }

    switch (num / 10) {
        case 9:
            printf("A \n");
            break;
        case 8:
            printf("B \n");
            break;
        case 7:
            printf("C \n");
            break;
        case 6:

        default:
            printf("D \n");
            break;
    }

    return 0;
}